/****** Object:  Stored Procedure dbo.spr_InsertDBHotels  ******/

 use [TourIS]
 GO

 if exists (select * from dbo.sysobjects where id = object_id(N'[dbo].[spr_InsertDBHotels]') and OBJECTPROPERTY(id, N'IsProcedure') = 1)
 drop procedure [dbo].[spr_InsertDBHotels]
 GO

 SET QUOTED_IDENTIFIER OFF
 GO
 SET ANSI_NULLS OFF
 GO

 CREATE  PROCEDURE [dbo].[spr_InsertDBHotels]
 (
	@compid int,
	@hotelid int,
	@hotelname varchar(50),
	@isactive bit,
	@isaprtment bit,
	@isroom bit,
	@issuite bit,
	@star int
 )
 AS

 BEGIN
	SET NOCOUNT ON
	DECLARE @Err int

	INSERT INTO [Hotels]
	(
		[CompId],
		[HotelId],
		[HotelName],
		[IsActive],
		[IsAprtment],
		[IsRoom],
		[IsSuite],
		[Star]
	)
	VALUES
	(
		@compid,
		@hotelid,
		@hotelname,
		@isactive,
		@isaprtment,
		@isroom,
		@issuite,
		@star
	)

	SET @Err = @@Error
	RETURN @Err
 END

 GO

 SET QUOTED_IDENTIFIER OFF
 GO
 SET ANSI_NULLS ON
 GO

